package org.hospital.entity;

// default package

import java.sql.Timestamp;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;

/**
 * Position entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "position", catalog = "hospital")
public class Position implements java.io.Serializable {

	// Fields

	private Integer positionId;
	private Integer creatorId;
	private String name;
	private String description = "null";
	private Integer rank;
	private Timestamp createTime;

	// Constructors

	/** default constructor */
	public Position() {
	}

	/** minimal constructor */
	public Position(Integer creatorId, String name, Integer rank, Timestamp createTime) {
		this.creatorId = creatorId;
		this.name = name;
		this.rank = rank;
		this.createTime = createTime;
	}

	/** full constructor */
	public Position(Integer creatorId, String name, String description, Integer rank,
			Timestamp createTime) {
		this.creatorId = creatorId;
		this.name = name;
		this.description = description;
		this.rank = rank;
		this.createTime = createTime;
	}

	// Property accessors
	@Id
	@GeneratedValue
	@Column(name = "positionId", unique = true, nullable = false)
	public Integer getPositionId() {
		return this.positionId;
	}

	public void setPositionId(Integer positionId) {
		this.positionId = positionId;
	}

	@Column(name = "creatorId", nullable = false)
	public Integer getCreatorId() {
		return this.creatorId;
	}

	public void setCreatorId(Integer creatorId) {
		this.creatorId = creatorId;
	}

	@Column(name = "name", nullable = false, length = 50)
	public String getName() {
		return this.name;
	}

	public void setName(String name) {
		this.name = name;
	}

	@Column(name = "description")
	public String getDescription() {
		return this.description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	@Column(name = "rank", nullable = false)
	public Integer getRank() {
		return this.rank;
	}

	public void setRank(Integer rank) {
		this.rank = rank;
	}

	@Column(name = "createTime", nullable = false, length = 19)
	public Timestamp getCreateTime() {
		return this.createTime;
	}

	public void setCreateTime(Timestamp createTime) {
		this.createTime = createTime;
	}

}